<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
{{assign var="title" value='历史登录信息'}}
{{assign var="app" value='user'}}
{{assign var="act" value='index'}}
{{assign var="table" value='user'}}
{{assign var="td" value='10'}}
<title>{{$title}}管理 - {{'admin|admin_site_name'|C|default:'后台管理'}}</title>
{{include file="include/base.html"}}
</head>
<body>

{{include file="include/sidebar.html"}}

<div class="body_right">
	<div id="content">

	<form action="index.php?app={{$app}}" method="post" name="form">
	<input type="hidden" name="app" value="{{$app}}"/>
	<input type="hidden" name="act" value="{{$act}}"/>
	<table class="table table-bordered textac">
		<tr class="thead">
		  <td colspan="{{$td}}">
		  ◆ {{$title}}管理 －> {{$title}}列表
		  </td>
		</tr>
		
		{{if !$result.data}}
		<tr class="noline"><td colspan="{{$td}}" class="result_empty"></td></tr>
		{{else}}
		<tr class="ttitle">
			<th>登录时间</th>
			<th>登出时间</th>
			<th>登录时长(小时)</th>
			<th>登录IP</th>
		</tr>
		<tbody>
			{{foreach item=val from=$result.data}}
			<tr>
				<td>{{$val.login_time|date_format:"%Y-%m-%d %H:%M:%S"}}{{if $val.login}}({{$val.login}}){{/if}}</td>
				<td>{{$val.loginout_time|date_format:"%Y-%m-%d %H:%M:%S"}}{{if $val.logout}}({{$val.logout}}){{/if}}</td>
				<td>{{$val.length}}</td>
				<td>{{$val.login_ip}}</td>
			</tr>
		    {{/foreach}}
		    <tr class="ttitle">
				<td colspan='4'>在线总时长：{{$result.online}}小时&nbsp;&nbsp;&nbsp;&nbsp;登录次数：{{$result.hit}}</td>
			</tr>
			<tr class="thead">
			  <td colspan="{{$td}}">
				{{include file="include/page.html"}}
			  </td>
			</tr>
		</tbody>
		{{/if}}
	</table>
	</form>
	
</div>
</div>

</body>
</html>